package com.hy.test;

import java.util.List;
import java.util.Map;

import org.springframework.context.support.ClassPathXmlApplicationContext;

import com.hy.mapper.AppMapper;

public class Main {
	
	public static void main(String[] args) {
		ClassPathXmlApplicationContext context = new ClassPathXmlApplicationContext("classpath:applicationContext.xml");
		AppMapper mapper = context.getBean(AppMapper.class);
		
		String sql = "select * from user";
		List<Map<String, Object>> result1 = mapper.executeQuery(sql);
		System.out.println(result1);

		List<Map<String, Object>> result2 = mapper.executeQuery2(sql);
		System.out.println(result2);
		
		context.close();
	}

}
